<!doctype html>
<html lang="en">
<head>
<script src="/brython.js"></script>
</head>
<body onload="brython()">
<script>
var obj = new Date()
t0 = obj.getTime()
for(i=0;i<10000;i++){Math.floor(10.3)}
var obj = new Date()
console.log('js '+(obj.getTime()-t0))

function $_MathClass(){}
$_MathClass.prototype.__getattr__ = function(attr){return this[attr]}
$_MathClass.prototype.floor = function(x){return int(Math.floor(x.value))}
function $_str(value){this.value=value}
_math = new $_MathClass()

var obj = new Date()
t0 = obj.getTime()
for(i=0;i<10000;i++){_math.__getattr__('floor')(float(10.3))}
var obj = new Date()
console.log('js '+(obj.getTime()-t0))

</script>

</body>
</html>


